package com.gaussian.property.admin.module.biz.vo.projectconfig;

import com.songqi.common.core.validationgroup.AddGroup;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.*;
import java.util.List;

/**
 * @description:
 * @author: songqi(13776346982)
 * @date: 2024/4/16 11:31
 */
@Data
@ApiModel("新增项目绑定的稽核表")
public class AddProjectCheckTable {


    /**
     * 项目id
     */
    @ApiModelProperty("项目id")
    @NotBlank(message = "项目未配置稽核表，联系管理员", groups = AddGroup.class)
    private String projectId;

    @ApiModelProperty("项目名称")
    @NotBlank(message = "项目名称必填", groups = AddGroup.class)
    private String projectName;

    /**
     * 稽核表id
     */
    @ApiModelProperty("稽核表(稽核标准)id")
    @NotBlank(message = "稽核表(稽核标准)id必填", groups = AddGroup.class)
    private String checkTableId;

    /**
     * 稽核周期。daily-每天、weekly-每周、monthly-每月
     */
    @ApiModelProperty("稽核周期。daily-每天、weekly-每周、monthly-每月")
    @NotBlank(message = "稽核周期必填")
    @Pattern(regexp = "daily|weekly|monthly", message = "稽核周期参数值错误")
    private String checkPeriod;

    /**
     * 每周期稽核次数
     */
    @ApiModelProperty("每周期稽核次数")
    @NotNull(message = "每周期稽核次数必填")
    @Min(1)
    private Integer countPerPeriod;

    /**
     * 合格分数
     */
    @ApiModelProperty("合格分数")
    @Min(value = 1, message = "合格分数只能是1-100")
    @Max(value = 100, message = "合格分数只能是1-100")
    private Integer passingScore;


    @ApiModelProperty("适用角色id")
    private List<String> roleIdList;

}
